<template>
    <!--轮播-->
    <div class="slider">
       <!-- <div class="layui-carousel" id="banner">
            <div carousel-item>
                <div><a href=""> <img class="img-banner" src="../../assets/book/images/banner1.jpg" alt=""></a></div>
                <div><a href=""> <img class="img-banner" src="../../assets/book/images/banner2.jpg" alt=""></a></div>
                <div><a href=""> <img class="img-banner" src="../../assets/book/images/banner3.jpg" alt=""></a></div>
                <div><a href=""> <img class="img-banner" src="../../assets/book/images/banner1.jpg" alt=""></a></div>
            </div>
        </div>-->
        <el-carousel indicator-position="outside" height="130px">
            <el-carousel-item v-for="item in 4" :key="item">
                <h3>
                    <a href=""> <img class="img-banner" src="../../assets/book/images/banner1.jpg" alt=""></a>
                   <!-- <a href=""> <img class="img-banner" src="../../assets/book/images/banner2.jpg" alt=""></a>
                    <a href=""> <img class="img-banner" src="../../assets/book/images/banner3.jpg" alt=""></a>
                    <a href=""> <img class="img-banner" src="../../assets/book/images/banner1.jpg" alt=""></a>-->
                </h3>
            </el-carousel-item>
        </el-carousel>
    </div>
</template>

<script>
    export default {

    }
    /*window.layui.use('carousel', ()=>{
        const carousel = window.layui.carousel;
        //建造实例
        carousel.render({
            elem: '#banner'
            ,width: '100%' //设置容器宽度
            ,arrow: 'always' //始终显示箭头
            ,interval:1500
            ,height:'180px'
            //,anim: 'updown' //切换动画方式
        });
    });*/

</script>

<style scoped>
    .slider{
        margin-top: 2.8rem;
    }
    .img-banner{
        /*height:100%;*/
        width:100%;
    }
    .el-carousel__item h3 {
        color: #475669;
        font-size: 18px;
        opacity: 0.75;
        line-height: 50px;
        margin: 0;
        height:10px;
    }
</style>